import request from '@/utils/request'

// 查询菜品列表
export function listCuisine(query) {
  return request({
    url: '/variety/cuisine/list',
    method: 'get',
    params: query
  })
}

// 查询菜品详细
export function getCuisine(cuisineId) {
  return request({
    url: '/variety/cuisine/' + cuisineId,
    method: 'get'
  })
}

// 新增菜品
export function addCuisine(data) {
  return request({
    url: '/variety/cuisine',
    method: 'post',
    data: data
  })
}

// 修改菜品
export function updateCuisine(data) {
  return request({
    url: '/variety/cuisine',
    method: 'put',
    data: data
  })
}

// 删除菜品
export function delCuisine(cuisineId) {
  return request({
    url: '/variety/cuisine/' + cuisineId,
    method: 'delete'
  })
}
export function dc(data){
  return request({
    url: '/variety/cuisine/dc',
    method: 'get',
    data: data
  })
}

// 查询优惠卷类型
export function type() {
  return request({
    url: '/variety/cuisine/type',
    method: 'get'
  })
}

export function url(){
  return request({
    url: '/variety/cuisine/url',
    method: 'get',
  })
}
